package org.example.ddd.autoconfig;

import jakarta.annotation.Resource;
import org.example.ddd.bean.LogAppProperties;
import org.example.ddd.service.LogImpl;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
@EnableConfigurationProperties({LogAppProperties.class})
public class AutoConfig {
    @Resource
    private LogAppProperties properties;

    @Bean
    public LogImpl logImpl() {
        return new LogImpl(properties);
    }


}